<!DOCTYPE html>
<html>
<head>
    <meta charset='utf-8'>
    <title>方德-新浪微博</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="FangDe desktop">
    <link rel="stylesheet" href="css/index.css" />
    <link rel="stylesheet" href="css/emoji.css" />
    <link rel="stylesheet" href="themes/pip_io/css/theme.css" />
    <link rel='stylesheet' href='js/lib/bootstrap-3.3.5/dist/css/bootstrap.css' />
    <style id="styleCustomResize"></style>
    <script src="js/lib/jquery-1.11.3/jquery-1.11.3.js"></script>
    <script src="js/lib/jquery-1.11.3/jquery.rotate.1-1.js" ></script>
    <!--<script src="js/lib/special_scroll.js"></script>-->
    <!--<script src="js/lib/jq.mobi.min.js"></script>-->
    <!--<script src="js/lib/keypress.js"></script>-->
    <!--<script src="js/patch.js"></script>-->
    <script src="./index.js"></script>
    <!--<script src="js/shortcuts.js"></script>-->
    <!--<script src='bootstrap/js/bootstrap.min.js'></script>-->
    <script>
        var i18n = require('./js/i18n');
        var _u = {
            // 向页面写内容
            w: function (s) {
                document.write(s);
            },
            // 向页面写本地化后的内容
            wi: function (s, e) {
                _u.w(i18n.get(s, e));
            },
            wia: function (sel, attr, s, e) {
                jq(sel).attr(attr, i18n.get(s, e));
            },
        };
    </script>
</head>

<body>
<!--/* <? 转换成 \n\');        ?>转换成  _buf.push('\n\*/  -->
<div id="wrapper">
    <div id="submitWarp">
        <div class="w">
            <ul id="accountsForSend"></ul>
            <textarea id="txtContent"></textarea>
            <div class="ctr">
                <span class="wordCount_double">140</span>
                /
                <span class="wordCount">140</span>
                &nbsp;
                <a id="btnAddEmotional" title="点击添加表情" data-target="txtContent">
                    <img src="images/face.gif" />表情
                </a>
                <a id="btnUploadPic" href="javascript:jq('#fileDialog').trigger('click');">
                    <img src="images/image.gif" />发图
                </a>
                <input class="hide" id="fileDialog" title="点击上传图片" type="file" />
                <button id="btnClearText" class="btn">清空</button>
                <!-- <span id="doingWarp"></span> -->
      <span class="hide">
      <a id="urlShortenBtn" title="缩短网址" href="javascript:;" onclick="addShortenUrl()"><img src="images/link_add.png" /></a>
      <input type="text" id="urlShortenInp" />
      </span>
                <input id="btnSend" title="发微！ ctrl + enter 发送" type="button" class="btn send" disabled="disabled" />
            </div>
        </div>
    </div><!-- submitWarp END 写微博部分-->
    <div id="header">
        <span id="loading"><img src="images/loader.gif" /></span>
        <div class="user">
            <a class="face" href="#"><img class="icon" src="images/1.gif" /><img class="bt" src="images/1.gif" /></a>
      <span class="info">
        <a class="name_link user_link" href="#"><span class="name"></span><br/></a>
        <span class="nums"></span>
      </span>
      <span class="top_btns">
        <span class="search_span">
          <a id="btnShowSearch" title="点击开始搜索" href="javascript:void(0);"
             class="search show_search_btn" title="点击开始搜索">
              <img src="images/search.png" />搜索
          </a>
          <span class="searchWrap">
            <input type="text" class="txtSearch" />
            <a id="btnSearch" title="点击开始搜索" href="javascript:void(0);" class="btnSearch">
                <img src="images/search.png" />
            </a>
            <img class="arrow" src="images/layerArrow.gif"/>
          </span>
        </span>
        <span class="user_search_span">
          <a id="btnShowSearchUser" title="点击开始搜人" href="javascript:void(0);"
             class="search search_user show_search_btn" title="点击开始搜索">
              <img src="images/face.gif" />搜人
          </a>
          <span class="searchWrap searchUserWrap">
            <input type="text" class="txtSearch" />
            <a id="btnSearchUser" title="点击开始搜人" href="javascript:" class="btnSearch">
                <img src="images/search.png" />
            </a>
            <img class="arrow" src="images/layerArrow.gif"/>
          </span>
        </span>
        <a id="btnLongText" title="点击发送长微博" href="javascript:void(0);" class="quickUpImg hide" onclick="openLongText();"><img src="images/longtext.png" />长微博</a>
        <a id="btnQuickUpImg" title="点击上传图片" href="javascript:void(0);" class="quickUpImg hide" onclick="openUploadImage();"><img src="images/image.gif" />发图</a>
      </span>
            <span id="topAd"></span>
            <a id="show_status_input" href="javascript:;" class="write">写微博<b></b></a>
        </div>
        <ul id="tl_tabs" class="tabs">
      <span class="btns">
        <a class="hide" id="scs">scs</a>
        <a herf="javascript:;" href="javascript:window.location='options.html';">配置</a>
        <a id="doingWithCapture" title="分享你正在看的网页并截图" class="hide" href="javascript:;"><img src="images/capture.png" /></a>
        <a id="btnForceRefresh" title="点击则当前用户马上获取最新" class="hide" href="javascript:;" onclick="forceRefresh(this)"><img src="images/refresh.png" /></a>
      </span>
            <li class="tab-friends_timeline timeline_tab" data-type="friends_timeline" href="#friends_timeline_timeline">首页<span class="unreadCount"></span></li>
            <li class="tab-mentions timeline_tab" data-type="mentions" href="#mentions_timeline">@我<span class="unreadCount"></span></li>
            <li class="tab-comments_mentions timeline_tab" data-type="comments_mentions" href="#comments_mentions_timeline">@评<span class="unreadCount"></span></li>
            <li class="tab-comments_timeline timeline_tab" data-type="comments_timeline" href="#comments_timeline_timeline">评论<span class="unreadCount"></span></li>
            <li class="tab-direct_messages_both timeline_tab" data-type="direct_messages_both" href="#direct_messages_both_timeline">私信<span class="unreadCount"></span></li>
            <li class="tab-favorites only_click timeline_tab" data-type="favorites" href="#favorites_timeline">收藏<span class="unreadCount"></span></li>
            <li class="tab-followers only_click timeline_tab hide" data-type="followers" href="#followers_timeline">粉丝<span class="unreadCount"></span></li>
            <li class="tab-user_timeline only_click timeline_tab" data-type="user_timeline" href="#user_timeline_timeline">微博<span class="unreadCount"></span></li>
        </ul>
        <div class="clearFix"></div>
    </div><!--微博的头部显示微博用户信息-->
    <div class="warp">
        <div id='friends_timeline_timeline' class="list_p">
            <div class="list_warp">
                <ul class="list"></ul>
                <div id="friends_timeline_rm_loading" class="readmore_loading"><img src="images/loading_s.gif" /></div>
            </div>
        </div>
        <div id="mentions_timeline" class="list_p" style="display:none;">
            <div class="list_warp">
                <ul class="list"></ul>
                <div id="mentions_rm_loading" class="readmore_loading"><img src="images/loading_s.gif" /></div>
            </div>
        </div>
        <div id="comments_mentions_timeline" class="list_p" style="display:none;">
            <div class="list_warp">
                <ul class="list"></ul>
                <div id="comments_mentions_rm_loading" class="readmore_loading"><img src="images/loading_s.gif" /></div>
            </div>
        </div>
        <div id="comments_timeline_timeline" class="list_p" style="display:none;">
            <div class="list_warp">
                <ul class="list"></ul>
                <div id="comments_timeline_rm_loading" class="readmore_loading"><img src="images/loading_s.gif" /></div>
            </div>
        </div>
        <div id="direct_messages_both_timeline" class="list_p" style="display:none;">
            <div class="list_warp">
                <div style="padding: 2px 0 0 10px;">
                    发私信给 @<input type="text" class="txtSearch" id="direct_message_user" />
                </div>
                <ul class="list"></ul>
                <div id="direct_messages_both_rm_loading" class="readmore_loading"><img src="images/loading_s.gif" /></div>
            </div>
        </div>
        <div id='favorites_timeline' class="list_p" style="display:none;">
            <div class="list_warp">
                <ul class="list"></ul>
                <div id="favorites_rm_loading" class="readmore_loading"><img src="images/loading_s.gif" /></div>
            </div>
        </div>
        <div id="followers_timeline" class="list_p" style="display:none;">
            <div class="list_warp">
                <div id="fans_tab" class="tab2">
                    <p>
                        <span class="tab_friends" t="friends"><font>我的</font>关注</span>
                        <span class="active tab_followers" t="followers"><font>我的</font>粉丝</span>
                    </p>
                </div>
                <ul class="list"></ul>
                <div id="followers_rm_loading" class="readmore_loading"><img src="images/loading_s.gif" /></div>
            </div>
        </div>
        <div id="user_timeline_timeline" class="list_p" style="display:none;">
            <div class="list_warp">
                <ul class="list"></ul>
                <div id="user_timeline_rm_loading" class="readmore_loading"><img src="images/loading_s.gif" /></div>
            </div>
        </div>

        <div id="accountListDock">
            <ul></ul>
        </div><!-- accountListDock END -->

        <span id="gototop" title="返回顶部" class="gototop" title="返回顶部"><img src="images/go_to_top.png" /></span>

    </div><!-- div.wrap END 显示微博的主页面部分，主要的信息box在该部分-->

    <!-- 表情选择 -->
    <div id="face_box" class="layerBox" style="display:none;">
        <div class="layerBoxCon1">
            <div class="faceItem clearFix">
                <div class="layerArrow"></div>
                <div class="face_tab tab2">
                    <p>
                        <a id="btnFaceBoxClose" title="关闭" class="close"></a>
                    </p>
                </div>
                <div class="faceItemPicbg">
                </div>
            </div>
        </div>
    </div>
    <input id="face_box_target_id" type="hidden" value="" />
    <!-- 表情选择 End -->
</div><!-- wrapper END -->

<div id="ye_dialog_window" >
    <a title="关闭 Close" href="javascript:void(0);" class="close_dialog" id="ye_dialog_close"></a>
    <div id="ye_dialog_title"></div>
    <div id="ye_dialog_body" >
        <div class="replyDialog">
            <textarea class="uTextarea" id="replyTextarea"></textarea><br/>
      <span id="replyInputCount" class="conTinge">
        (还可以输入
        <span class="wordCount_double">140</span>
        /
        <span class="wordCount">140</span>
        字)
      </span>

            <a id="btnAddReplyEmotional" title="点击添加表情" data-target="replyTextarea">
                <img src="images/face.gif" />表情
            </a>
            <p>
                <input type="checkbox" id="chk_sendOneMore" />
                <label for="chk_sendOneMore" id="txt_sendOneMore"></label><br/>
                <input type="checkbox" id="chk_sendOneMore2" />
                <label for="chk_sendOneMore2" id="txt_sendOneMore2"></label><br/>
                <input type="checkbox" id="chk_originalComment" />
                <label for="chk_originalComment" id="txt_originalComment">包含原评论</label>
            </p>
            <button id="replySubmit" title="ctrl + enter 发送" type="button" title="按 ctrl + enter 发送" class="send btn" style="float: right;">发微！</button>
            <a href="javascript:void(0);" class="close_dialog" style="float: right; color: #99a8bb; margin-right: 20px; margin-top: 5px; font-size: 10px;">关闭</a>
        </div>
    </div>
    <input type="hidden" id="actionType" value="" />
    <input type="hidden" id="replyTweetId" value="" />
    <input type="hidden" id="replyUserName" value="" />
    <input type="hidden" id="replyUserId" value="" />
    <input type="hidden" id="whisperToUserId" value="" />
    <input type="hidden" id="repostTweetId" value="" />
    <input type="hidden" id="commentUserId" value="" />
    <input type="hidden" id="commentTweetId" value="" />
    <input type="hidden" id="commentCommentId" value="" /><!-- 回复的评论ID -->
</div><!--这个是转发，评论输入文字的小窗口的小窗口-->

<div id="msgInfoWarp"></div>

<!-- 上传图片预览 -->
<div id="upImgPreview" class="upload_image_preview">
    <img class="arrow" src="images/layerArrow.gif" />
    <a class="close" href="javascript:window.imgForUpload = null; $('#upImgPreview').hide(); $('#txtContent').focus();" title="Close"></a>
    <div class="img"></div>
    <div class="loading_bar"><div><span></span></div></div>
</div>
<div id="upImgPreview_reply" class="upload_image_preview">
    <img class="arrow" src="images/layerArrow.gif" />
    <a class="close"
       href="javascript:window.imgForUpload_reply = null; $('#upImgPreview_reply').hide(); countReplyText();"
       title="Close"></a>
    <div class="img"></div>
    <div class="loading_bar"><div><span></span></div></div>
</div>

<!-- 模板选择 -->
<script id="tp_time_line" type="text/template">

    <li class="tweetItem showCounts_#{tweet.id} <?js if (!tweet.readed) { ?>unread-item<?js } ?> <?js if (tweet.myTweet) { ?>myTweet<?js } ?> " id="tweet#{tweet.id}"
        data-id="#{tweet.id}" data-timestamp="#{tweet.timestamp || ''}"
        data-uid="#{tweet.user.id}" data-screen_name="#{tweet.user.screen_name}">

        <div class="li_wrap clearFix #{tweet.is_me ? 'li_wrap_is_me' : ''}">
            <div class="usericon">
                <span class="showtip">
                <a class="user_head user_link" data-uid="#{user.id}" rhref="#{user.t_url}">
                    <img src="#{ user.profile_image_url }" />
                </a>
                </span>
            </div>
            <div class="mainContent commentWrap">
                <span class="arrow_r"></span>
                <div class="userName">
                    <a class="user_link" data-uid="#{user.id}" rhref="#{user.t_url}" title="#{getUserCountsInfo(user)}">
                        #{user.screen_name}<?js if (user.verified) { ?><img title="认证用户"
                                                                            src="images/verified#{user.verified_type && user.verified_type > 0 ? '_blue.png' : '.gif'}" /><?js } ?>
                    </a>
                    <?js if (show_fullname) { ?><span class="fullname">#{user.name}</span> <?js } ?>

                </div>
                <div class="msg">
                    <div class="tweet">
                        <div class="tweet_text">
                            #{tweet.text}
                            <?js if (tweet.crosspostSource) { ?>
                            <a target="_blank" href="#{tweet.crosspostSource}" title="查看原文">查看原文</a>
                            <?js } ?>
                        </div>

                        <?js if (tweet.thumbnail_pic) { ?>
                        <div>
                            <?js
                              var pics = [];
                              if (!Array.isArray(tweet.thumbnail_pic)) {
                                pics = [[tweet.thumbnail_pic, tweet.bmiddle_pic, tweet.original_pic]];
                              } else {
                                for (var i = 0; i < tweet.thumbnail_pic.length; i++) {
                                  pics.push([tweet.thumbnail_pic[i], tweet.bmiddle_pic[i], tweet.original_pic[i]]);
                                }
                              }
                              for (var i = 0; i < pics.length; i++) {
                                var pic = pics[i];
                                ?>
                            <a target="_blank" href="javascript:void(0);" bmiddle="#{pic[1]}"
                               original="#{pic[2]}" title="右键点击打开原图"
                            class="thumbnail_pic" >
                            <img class="imgicon pic" src="#{pic[0]}" />
                            </a>
                            <?js } ?>
                        </div>
                        <?js } ?>

                        <?js if (tweet.retweet_me || tweet.retweet_user) { ?>
                        <div class="retweet_info">由 <?js if(tweet.retweet_me){ ?>
                            <a target="_blank" data-uid="#{tweet.retweet_me.id}" class="user_link"
                               rhref="#{tweet.retweet_me.t_url}">
                                #{tweet.retweet_me.screen_name}<?js if (tweet.retweet_me.verified) { ?><img title="认证用户" src="images/verified#{tweet.retweet_me.verified_type && tweet.retweet_me.verified_type > 0 ? '_blue.png' : '.gif'}" /><?js } ?>
                            </a>
                            <?js if (show_fullname) { ?><span class="fullname">#{tweet.retweet_me.name}</span> <?js } ?>
                            <?js } ?>
                            <?js if (tweet.retweet_user) { ?>
                            <?js if (tweet.retweet_me) { ?>、<?js } ?>
                            <a target="_blank" data-uid="#{tweet.retweet_user.id}" class="user_link"
                               rhref="#{tweet.retweet_user.t_url}">
                                #{tweet.retweet_user.screen_name}<?js if (tweet.retweet_user.verified) { ?><img title="认证用户" src="images/verified#{tweet.retweet_user.verified_type && tweet.retweet_user.verified_type > 0 ? '_blue.png' : '.gif'}" /><?js } ?>
                            </a>
                            <?js if (show_fullname) { ?><span class="fullname">#{tweet.retweet_user.name}</span> <?js } ?>
                            <?js } ?> 等转发</div>
                        <?js } ?>
                    </div>
                    <?js if (tweet.retweeted_status && tweet.retweeted_status.text) { ?>
                    <!-- 转发 -->
                    <!-- {{retweeted_status_in}} -->
                    <!-- 转发 End -->
                    <?js } ?>
                </div>

                <?js if (tweet.created_at) { ?>
                <div class="msgInfo">
                    <?js if (tweet.t_url) { ?>
                    <a data-href="#{tweet.t_url}">#{tweet.created_at}</a>
                    <?js } else { ?>
                    #{tweet.created_at}
                    <?js } ?>
                    通过 #{(tweet.source || "网站").replace('href=', 'data-href=')}
                    <?js if (!tweet.retweeted_status && tweet.in_reply_to_status_id && tweet.in_reply_to_screen_name) { ?>
                    <a href="javascript:void(0);" class="show_source_status_btn" status_id="#{tweet.in_reply_to_status_id}"
                       title="查看原信息">#{_u.i18n("btn_show_source_status", [tweet.in_reply_to_screen_name])}</a>
                    <?js } ?>
                    <!-- 提示私信是回复给谁的 -->

                    <?js } ?>
                    <!-- 收藏时间 -->
                </div>
            </div>
        </div> <!-- end .li_wrap -->
        <?js if (tweet.retweeted_status && tweet.retweeted_status.text) { ?>
        <!-- 转发 -->
        <!-- {{retweeted_status_out}} -->
        <!-- {{retweeted_retweeted_status_out}} -->
        <!-- 转发 End -->
        <?js } ?>
    </li>
</script>

<!-- 转发模板（包括评论、@我的所带的原status） -->
<!-- 转发 -->
<script id="tp_time_line_rt" type="text/template">

    <div class="msg">
        <div class="tweetItem retweeted commentWrap showCounts_#{tweet.retweeted_status.id} <?js if (is_rt_rt){ ?>rt_retweeted<?js } ?>" id="tweet#{tweet.retweeted_status.id}"
             data-id="#{tweet.retweeted_status.id}" data-timestamp="#{tweet.retweeted_status.timestamp || ''}">

            <div class="userName">
                <?js if (is_rt_rt) { ?>
      <span class="showtip">
        <a class="user_link" data-uid="#{tweet.user.id}">
            @#{tweet.user.screen_name}
        </a>
          <?js if (show_fullname) { ?><span class="fullname">#{tweet.user.name}</span> <?js } ?>
      </span>
                <?js } ?>
                <?js if (!is_rt_rt) { ?>
                #{_u.i18n('comm_comment_to_before')}
                <?js } else { ?>
                #{_u.i18n('comm_repost_to_before')}
                <?js } ?>
      <span class="showtip">
        <a target="_blank" data-uid="#{tweet.retweeted_status.user.id}" class="user_link"
           rhref="#{tweet.retweeted_status.user.t_url}">
            @#{tweet.retweeted_status.user.screen_name}<?js if(tweet.retweeted_status.user.verified){ ?><img title="#{_u.i18n('comm_verified')}" src="images/verified#{tweet.retweeted_status.user.verified_type && tweet.retweeted_status.user.verified_type > 0 ? '_blue.png' : '.gif'}" /><?js } ?>
        </a>
          <?js if (show_fullname) { ?><span class="fullname">#{tweet.retweeted_status.user.name}</span> <?js } ?>
      </span>
                #{_u.i18n("comm_repost_to_after")}:
            </div>

            <div class="tweet_text">#{tweet.retweeted_status.text}
                <?js if (tweet.crosspostSource) { ?>
                <a target="_blank" href="#{tweet.crosspostSource}"
                   title="#{_u.i18n('comm_show_original')}">#{_u.i18n('comm_show_original')}</a>
                <?js } ?>
            </div>
            <?js if (tweet.retweeted_status.thumbnail_pic) { ?>
            <div>
                <a target="_blank" href="javascript:void(0);"
                   bmiddle="#{tweet.retweeted_status.bmiddle_pic}"
                   title="#{_u.i18n("btn_show_original_pic_title")}"
                original="#{tweet.retweeted_status.original_pic}"
                class="thumbnail_pic" >
                <img class="imgicon pic" src="#{tweet.retweeted_status.thumbnail_pic}" /></a>
            </div>
            <?js } ?>

            <!-- {{retweeted_retweeted_status_in}} -->
            <?js if (tweet.retweeted_status.created_at) { ?>
            <div class="msgInfo">
                <?js if (tweet.retweeted_status.t_url) { ?>
                <a data-href="#{tweet.retweeted_status.t_url}">#{tweet.retweeted_status.created_at}</a>
                <?js } else { ?>
                #{tweet.retweeted_status.created_at}
                <?js } ?>
                #{_u.i18n('comm_post_by')} #{(tweet.retweeted_status.source || _u.i18n("comm_web_site")).replace('href=', 'data-href=')}
                <?js if (!tweet.retweeted_status.retweeted_status &&
               tweet.retweeted_status.in_reply_to_status_id &&
               tweet.retweeted_status.in_reply_to_screen_name) { ?>
                <a href="javascript:void(0);" class="show_source_status_btn"
                   status_id="#{tweet.retweeted_status.in_reply_to_status_id}"
                   title="#{_u.i18n('comm_show_original_status')}">
                    #{_u.i18n("btn_show_source_status", [tweet.retweeted_status.in_reply_to_screen_name])}</a>
                <?js } ?>
            </div>
            <?js } ?>

        </div>

    </div>

</script>
<!-- 转发 End -->


<script>
    var TEMPLATE = $("#tp_time_line").html();/*微博主模板*/
    var TEMPLATE_RT = $("#tp_time_line_rt").html();
</script>

</body>
</html>



